﻿<%@ Page Title="Remove data source" Language="C#" MasterPageFile="~/Demo.master" Inherits="DemoPage" %>

<%@ Register Src="~/CodeFormatter.ascx" TagName="Code" TagPrefix="demo" %>
<asp:Content ID="Content1" ContentPlaceHolderID="DemoHolder" runat="Server">
    <div class="dna-state-help ui-corner-all" style="margin-bottom: 10px;">
        In the sample below, the textbox is associated with an AutoComplete that pulls words
        that start with the contents of the textbox using a web service. Set the <b>ServiceMethod</b>
        and <b>ServicePath</b> to your web service. 
        <div style="margin-top:5px;">
        <i>Remark: The signature of this method
            must match the following:</i>
        <demo:Code runat="server" ID="webservicecode" Language="c#">
        <Code>
[WebMethod]
[ScriptMethod(ResponseFormat = ResponseFormat.Json)]
public string[] GetData(string prefix, int count)
        </Code>
        </demo:Code>
        </div>
    </div>
    <div class="ui-widget">
        <label>
            Tags:</label><asp:TextBox runat="server" Text="" ID="Text1"></asp:TextBox>
    </div>
    <DotNetAge:AutoComplete runat="server" ID="AutoCompelete1" ServiceMethod="GetData"
        ServicePath="~/AutoComplete/WebService.asmx">
        <Target TargetID="Text1" />
    </DotNetAge:AutoComplete>
    <br />
    <demo:Code runat="server" ID="codeView" SourceFile="~/AutoComplete/Codes/RemoteDataSample.aspx" />
</asp:Content>
